package com.dime.physical.service.impl;

import java.util.List;
import com.ruoyi.common.core.utils.DateUtils;
import org.springframework.beans.factory.annotation.Autowired;
import org.springframework.stereotype.Service;
import com.dime.physical.mapper.DimeMaincheckharmconclusionMapper;
import com.dime.physical.domain.DimeMaincheckharmconclusion;
import com.dime.physical.service.IDimeMaincheckharmconclusionService;

/**
 * 危害结论Service业务层处理
 * 
 * @author Tiny
 * @date 2023-10-17
 */
@Service
public class DimeMaincheckharmconclusionServiceImpl implements IDimeMaincheckharmconclusionService 
{
    @Autowired
    private DimeMaincheckharmconclusionMapper dimeMaincheckharmconclusionMapper;

    /**
     * 查询危害结论
     * 
     * @param id 危害结论主键
     * @return 危害结论
     */
    @Override
    public DimeMaincheckharmconclusion selectDimeMaincheckharmconclusionById(String id)
    {
        return dimeMaincheckharmconclusionMapper.selectDimeMaincheckharmconclusionById(id);
    }

    /**
     * 查询危害结论列表
     * 
     * @param dimeMaincheckharmconclusion 危害结论
     * @return 危害结论
     */
    @Override
    public List<DimeMaincheckharmconclusion> selectDimeMaincheckharmconclusionList(DimeMaincheckharmconclusion dimeMaincheckharmconclusion)
    {
        return dimeMaincheckharmconclusionMapper.selectDimeMaincheckharmconclusionList(dimeMaincheckharmconclusion);
    }

    /**
     * 新增危害结论
     * 
     * @param dimeMaincheckharmconclusion 危害结论
     * @return 结果
     */
    @Override
    public int insertDimeMaincheckharmconclusion(DimeMaincheckharmconclusion dimeMaincheckharmconclusion)
    {
        dimeMaincheckharmconclusion.setCreateTime(DateUtils.getNowDate());
        return dimeMaincheckharmconclusionMapper.insertDimeMaincheckharmconclusion(dimeMaincheckharmconclusion);
    }

    /**
     * 修改危害结论
     * 
     * @param dimeMaincheckharmconclusion 危害结论
     * @return 结果
     */
    @Override
    public int updateDimeMaincheckharmconclusion(DimeMaincheckharmconclusion dimeMaincheckharmconclusion)
    {
        dimeMaincheckharmconclusion.setUpdateTime(DateUtils.getNowDate());
        return dimeMaincheckharmconclusionMapper.updateDimeMaincheckharmconclusion(dimeMaincheckharmconclusion);
    }

    /**
     * 批量删除危害结论
     * 
     * @param ids 需要删除的危害结论主键
     * @return 结果
     */
    @Override
    public int deleteDimeMaincheckharmconclusionByIds(String[] ids)
    {
        return dimeMaincheckharmconclusionMapper.deleteDimeMaincheckharmconclusionByIds(ids);
    }

    /**
     * 删除危害结论信息
     * 
     * @param id 危害结论主键
     * @return 结果
     */
    @Override
    public int deleteDimeMaincheckharmconclusionById(String id)
    {
        return dimeMaincheckharmconclusionMapper.deleteDimeMaincheckharmconclusionById(id);
    }
}
